package com.zhenwei.zscm.model.vo.dict;

import com.zhenwei.zscm.common.annotations.Delete;
import com.zhenwei.zscm.common.annotations.Insert;
import com.zhenwei.zscm.common.annotations.Update;
import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotEmpty;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

@Data
public class DictVO {
    @NotEmpty(message = "主键ID不能为空", groups = {Update.class})
    private String guid;
    @NotEmpty(message = "字典编码不能为空", groups = {Insert.class, Update.class, Delete.class})
    private String code;
    @NotEmpty(message = "字典名称不能为空", groups = {Insert.class, Update.class})
    private String name;
    @NotEmpty(message = "字典类别不能为空", groups = {Insert.class, Update.class, Delete.class})
    private String dictType;
    @NotNull(message = "排序不能为空", groups = {Insert.class, Update.class})
    @Min(value = 0, message = "排序值不能小于0")
    private Integer orderBy;
}
